package example.demo.entity;

import lombok.AllArgsConstructor;
import lombok.Data;

/*
 * @Component
 * public class FactoryBeanStudent implements FactoryBean<Student>{......}
 * FactoryBeanStudent是加入到BeanFactory的singletonObjects这个map
 * Student是加入到BeanFactory的factoryBeanObjectCache这个map
 * <p>
 * Student
 * applicationContext.getBean(Student.class)//student
 * applicationContext.getBean("factoryBeanStudent")//student
 * <p>
 * FactoryBeanStudent
 * applicationContext.getBean("&factoryBeanStudent")//FactoryBeanStudent
 * applicationContext.getBean(FactoryBeanStudent.class)//FactoryBeanStudent
 */
@Data
@AllArgsConstructor
public class Student {
    private String name;
    private Integer age;
}
